package com.evil.common.account.dto.user;

import com.evil.common.account.enums.IsManageEnum;
import com.evil.common.core.dto.FindByIdsReqDTO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Collection;

/**
 * @author liyang
 * @date 2023-01-08 16:10
 */
@Data
@EqualsAndHashCode(callSuper = true)
public class FindUserIdsByIdsReqDTO extends FindByIdsReqDTO {

    /**
     * 是否部门主管
     */
    private Integer isManager;

    public FindUserIdsByIdsReqDTO() {
    }

    public FindUserIdsByIdsReqDTO(Collection<Long> ids, Boolean filterDeleted, Boolean cache, Integer isManager) {
        super(ids, filterDeleted, cache);
        this.isManager = isManager;
    }

    public static FindUserIdsByIdsReqDTO filter(Collection<Long> ids) {
        return new FindUserIdsByIdsReqDTO(ids, true, false, IsManageEnum.MANAGE.getId());
    }
}
